package cn.tedu.xctf.boot1.controller;


import cn.tedu.xctf.boot1.entity.Emp;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

@Controller
public class ParamController {

    @RequestMapping("/p1")
    @ResponseBody
    public String p1(String info){

        return "接收到了参数"+info;
    }

    @RequestMapping("/p2")
    @ResponseBody
    public String p2(String name,String sal,String job){
        return "名字:"+name+"工资:"+sal+"工作:"+job;
    }

    @RequestMapping("/p3")
    @ResponseBody
    public String p3(Emp emp){
        return emp.toString();
    }
}
